﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Text.RegularExpressions;

namespace Test
{
    class Program
    {
        static void Main(string[] args)
        {
            //new HistoryDataRetriever().GetTradingDataFromCafef();
            new HistoryDataRetriever().GetPriceDataFromCafef();
            //new HistoryDataRetriever().GetForeignDataFromCafef();
            //DoTest();
        }

        private static void DoTest()
        {
            string input = @"<td class=""Item_ChangePrice""><span class=Index_Down>-0.9 (-3.9 %)</span></td>";
            Regex regex = new System.Text.RegularExpressions.Regex(@"\<span((?!(\<\/span\>)).)*\>");
            input = regex.Replace(input, String.Empty);
            regex = new System.Text.RegularExpressions.Regex(@"\<\/span\>");
            input = regex.Replace(input, String.Empty);
            regex = new Regex(@"\([-\.\d]+\s%\)");
            input = regex.Replace(input, String.Empty);

            Console.WriteLine(input);
        }
    }
}
